cmake_minimum_required(VERSION 3.12)
project(simple_viewer)

add_executable(${PROJECT_NAME} main.cpp)

target_link_libraries(${PROJECT_NAME} PRIVATE
    ${OpenCV_LIBS}
    spdlog::spdlog
    vision
    device
)

target_include_directories(${PROJECT_NAME} PRIVATE
    ${CMAKE_CURRENT_SOURCE_DIR}
    ${CMAKE_CURRENT_SOURCE_DIR}/..
    $<TARGET_PROPERTY:device,INTERFACE_INCLUDE_DIRECTORIES>
    $<TARGET_PROPERTY:vision,INTERFACE_INCLUDE_DIRECTORIES>
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/rplidar/sdk/include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/third_party/d2c/Include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/third_party/OpenNI2/Include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/third_party/UvcSwapper/Include/
)

target_include_directories(${PROJECT_NAME} PUBLIC
    /opt/MVS/include
    ${CMAKE_CURRENT_SOURCE_DIR}
    ${CMAKE_CURRENT_SOURCE_DIR}/../component/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/rplidar/sdk/include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/rplidar/sdk/src/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/third_party/d2c/Include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/third_party/OpenNI2/Include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/third_party/UvcSwapper/Include/
    ${CMAKE_CURRENT_SOURCE_DIR}/../../third_party/orbbec/Include/
)

add_dependencies(${PROJECT_NAME}
    device
)